#include <stdio.h>
#define MAXN 10

void format (int num)
{
	int digit[MAXN];
	int digitp = -1;
	int i;

	if (num < 0) {
		printf("-");
		num = -num;
	}

	if (num==0) {
		printf ("0");
		return ;
	}

	while (num) {
		digit[++digitp] = num%10;
		num/=10;
	}

	if (digitp < 3) {
		for(i=digitp;i>=0;i--)
			printf("%d",digit[i]);
	} else if (digitp < 6) {
		for(i=digitp;i>=0;i--) {
			printf("%d",digit[i]);
			if (i==3) printf(",");
		}
	} else {
		for(i=digitp;i>=0;i--) {
			printf("%d",digit[i]);
			if (i==3 || i==6) printf(",");

		}
	}
}

int main (void)
{
	int a, b;
	int c;
	scanf ("%d %d", &a, &b);
	c = a+b;
	format(c);
	return 0;
}
